var co = require('co');
var thunkify = require('thunkify');

var fs = require('fs');
var readFile = thunkify(fs.readFile);

var gen = function* (){
  var f1 = yield readFile('/etc/fstab');
  var f2 = yield readFile('/etc/shells');
  console.log("2"+f2.toString());
  console.log("1"+f1.toString());

};

co(gen).then(function(){
    console.log('Generator 函数执行完成');
});